//package com.zmn.plat.dubbo.impl.product;
//
//import javax.annotation.Resource;
//
//import org.apache.dubbo.config.annotation.Service;
//
//import com.zmn.common.dto2.ResponseDTO;
//import com.zmn.plat.common.dto.product.ServSubsidiaryItemDIO;
//import com.zmn.plat.common.dto.product.ServSubsidiaryItemDRO;
//import com.zmn.plat.dubbo.interfaces.product.ServSubsidiaryItemModifyRemoteService;
//import com.zmn.plat.dubbo.utils.DubboConsts;
//import com.zmn.plat.model.entity.product.ServSubsidiaryItem;
//import com.zmn.plat.services.interfaces.product.ServSubsidiaryItemService;
//import com.zmn.plat.utils.bean.BeanCopyUtils;
//
//import lombok.extern.slf4j.Slf4j;
//
///**
// * @author tanghongjun
// * @version v1.0 @类说明：
// * @since 2018/10/16 11:30
// */
//@Slf4j
//@Service(version = DubboConsts.INTERFACE_VERSION, validation = "true")
//public class ServSubsidiaryItemModifyRemoteServiceImpl implements ServSubsidiaryItemModifyRemoteService {
//
//    private static final String TAG = "故障服务分组 dubbo 接口";
//
//    @Resource
//    private ServSubsidiaryItemService servSubsidiaryItemService;
//
//    @Override
//    public ResponseDTO<ServSubsidiaryItemDRO> add(ServSubsidiaryItemDIO servSubsidiaryItemDIO) {
//        log.info("add params is: servSubsidiaryItemDIO={}", servSubsidiaryItemDIO);
//
//        ServSubsidiaryItem servSubsidiaryItem = new ServSubsidiaryItem();
//        BeanCopyUtils.copyProperties(servSubsidiaryItemDIO, servSubsidiaryItem);
//        servSubsidiaryItemService.insert(servSubsidiaryItem);
//
//        return this.returnDRO(servSubsidiaryItem);
//    }
//
//    @Override
//    public ResponseDTO<ServSubsidiaryItemDRO> modifyByKey(ServSubsidiaryItemDIO servSubsidiaryItemDIO) {
//        log.info("modifyByKey params is: servSubsidiaryItemDIO={}", servSubsidiaryItemDIO);
//
//        ServSubsidiaryItem servSubsidiaryItem = new ServSubsidiaryItem();
//        BeanCopyUtils.copyProperties(servSubsidiaryItemDIO, servSubsidiaryItem);
//        servSubsidiaryItemService.updateByKey(servSubsidiaryItem);
//
//        return this.returnDRO(servSubsidiaryItem);
//    }
//
//    private ResponseDTO<ServSubsidiaryItemDRO> returnDRO(ServSubsidiaryItem servSubsidiaryItem) {
//        ServSubsidiaryItemDRO servSubsidiaryItemDRO = new ServSubsidiaryItemDRO();
//        BeanCopyUtils.copyProperties(servSubsidiaryItem, servSubsidiaryItemDRO);
//
//        return ResponseDTO.success(servSubsidiaryItemDRO, "OK");
//    }
//}
